#app {
  // 主体区域 Main container
  .main-container {
    min-height: 100%;
    transition: margin-left 0.28s;
    margin-left: $sideBarWidth;
    position: relative;
    & > .app-container {
      position: absolute;
      height: 100%;
      width: 100%;
      overflow-y: auto;
      background-color: #f1f1f1;
      padding: 20px;
    }
  }

  // 侧边栏 Sidebar container
  .sidebar-container {
    transition: width 0.28s;
    width: $sideBarWidth !important;
    height: 100%;
    position: fixed;
    font-size: 0px;
    top: 0;
    bottom: 0;
    left: 0;
    z-index: 1001;
    overflow: hidden;
    padding-top: $topBarHeight;
    padding-bottom: $topBarHeight;
    background: $menuBg;

    .scrollbar-wrapper {
      overflow-x: hidden !important;

      .el-scrollbar__view {
        height: 100%;

        .el-menu {
          height: 100%;
          width: 100% !important;
          border: none;
        }

        .el-menu-item:hover {
          background-color: $menuHover;
        }

        .el-menu-item.is-active {
          background-color: $menuBgActive;
        }

        .el-sub-menu__title:hover {
          background-color: $menuHover !important;
        }

        .el-menu--collapse .el-sub-menu {
          .el-sub-menu__title span {
            height: 0;
            width: 0;
            overflow: hidden;
            visibility: hidden;
          }

          .el-sub-menu__icon-arrow {
            display: none;
          }
        }

        .el-sub-menu .el-menu-item {
          width: 100%;
          min-width: 0;
          padding-left: 50px;
        }
      }
    }

    a {
      display: inline-block;
      width: 100%;
      overflow: hidden;
      text-decoration: none;
    }
  }

  .hideSidebar {
    .sidebar-container {
      width: 36px !important;
    }

    .main-container {
      margin-left: 36px;
    }
    .el-menu-item .el-menu-tooltip__trigger {
      padding: 0 10px;
    }
    .el-sub-menu {
      & > .el-sub-menu__title {
        padding: 0 10px;
      }
    }
  }

  // 适配移动端, Mobile responsive
  .mobile {
    .main-container {
      margin-left: 0px;
    }

    .sidebar-container {
      transition: transform 0.28s;
    }

    &.hideSidebar {
      .sidebar-container {
        pointer-events: none;
        transition-duration: 0.3s;
        transform: translate3d(-$sideBarWidth, 0, 0);
      }
    }
  }

  .withoutAnimation {
    .sidebar-container {
      transition: none;
    }
    .main-container {
      transition: none;
    }
  }
}

.nest-menu:hover {
  .el-menu-item {
    background-color: $menuHover;
  }
}
.nest-menu {
  .el-menu-item.is-active {
    background-color: $menuBgActive;
  }
}
